<html>
    <head>
        <title>Template Test</title>
        <meta charset="utf-8">

        <script type="text/javascript" src="js/angular.min.js"></script>
        <style>
            * {
                font-family: "微软雅黑";
            }
        </style>
    </head>
    <body>
        <h2>{{title}}</h2>
        {{#list}}
            <div>{{name}} : {{age}}</div>
        {{/list}}
        <div ng-app="myApp" ng-controller="userCtrl">
            <ul>
                <li ng-repeat="item in items">
                    {{item.name}} : {{item.age}}
                </li>
            </ul>
        </div>

        <script>
            var app = angular.module("myApp", []);
            app.controller("userCtrl", function($scope, $http){
                $http.get("/profile/users").success(function(data){
                    $scope.items = data.users;
                }).error(function(data, status){
                    alert(status + " : " + data);
                });
                
            });
        </script>
    </body>
</html>